package com.seecoder.BlueWhale.exception;

/**
 * @Author: DingXiaoyu
 * @Date: 0:26 2023/11/26
 * 你可以在这里自定义Exception
 */
public class BlueWhaleException extends RuntimeException {

    public BlueWhaleException(String message) {
        super(message);
    }

    public static BlueWhaleException phoneAlreadyExists() {
        return new BlueWhaleException("手机号已经存在!");
    }

    public static BlueWhaleException notLogin() {
        return new BlueWhaleException("未登录!");
    }

    public static BlueWhaleException phoneOrPasswordError() {
        return new BlueWhaleException("手机号或密码错误!");
    }

    public static BlueWhaleException fileUploadFail() {
        return new BlueWhaleException("文件上传失败!");
    }

    public static BlueWhaleException storeNameAlreadyExists() {
        return new BlueWhaleException("商店名称已存在!");
    }

    public static BlueWhaleException commodityPhotosNeeded() {
        return new BlueWhaleException("商品图片数量不足!");
    }

    public static BlueWhaleException notChooseStoreID() {
        return new BlueWhaleException("工作人员未选择所属商店!");
    }

    public static BlueWhaleException notUploadStoreLogo() {
        return new BlueWhaleException("未上传商店图片！");
    }

    public static BlueWhaleException cannotFindCommodity() {
        return new BlueWhaleException("找不到商品！");
    }

    public static BlueWhaleException cannotFindStore() {
        return new BlueWhaleException("找不到商店！");
    }

    public static BlueWhaleException notChooseRole() {
        return new BlueWhaleException("未选择用户身份！");
    }

    public static BlueWhaleException CommodityIdNotGiven() {
        return new BlueWhaleException("未给出商品id");
    }

    public static BlueWhaleException stuffAccessCheckFail() {
        return new BlueWhaleException("工作人员权限检查失败！");
    }

    public static BlueWhaleException managerAccessCheckFail() {
        return new BlueWhaleException("商场管理员权限检查失败！");
    }

    public static BlueWhaleException ceoAccessCheckFail() {
        return new BlueWhaleException("CEO权限检查失败！");
    }

    public static BlueWhaleException CommodityInsufficient() {
        return new BlueWhaleException("商品库存不足！");
    }

    public static BlueWhaleException customerAccessCheckFail() {
        return new BlueWhaleException("顾客权限检查失败！");
    }

    public static BlueWhaleException orderStatusWrong() {
        return new BlueWhaleException("订单状态异常");
    }

    public static BlueWhaleException orderNotFound() {
        return new BlueWhaleException("未查询到订单");
    }

    public static BlueWhaleException storeAccessInvalid() {
        return new BlueWhaleException("商店权限错误！");
    }

    public static BlueWhaleException cannotFindUser() {
        return new BlueWhaleException("找不到用户!");
    }

    public static BlueWhaleException managerAccessInvalid() {
        return new BlueWhaleException("管理员无此权限！");
    }

    public static BlueWhaleException invalidInput() {
        return new BlueWhaleException("输入不合法！");
    }

    public static BlueWhaleException cannotFindCouponGroup() {
        return new BlueWhaleException("找不到优惠券组！");
    }

    public static BlueWhaleException invalidExcelRequest() {
        return new BlueWhaleException("无权查看报表！");
    }

    public static BlueWhaleException payError() {
        return new BlueWhaleException("支付失败！");
    }

    public static BlueWhaleException sha256Error() {
        return new BlueWhaleException("SHA-256加密出错！");
    }

    public static BlueWhaleException invalidCoupon() {
        return new BlueWhaleException("无效优惠券！");
    }
}
